package com.tuanzi.loan.web.lazy.family.largeAmount;

import com.tuanzi.loan.business.service.family.LoanLargeOuterTemplateService;
import com.tuanzi.loan.core.lazy.BaseLazyDataModel;
import com.tuanzi.loan.core.util.SpringContextHolder;
import com.tuanzi.loan.core.vo.PageSearcher;
import com.tuanzi.loan.vo.request.family.LoanLargeOuterTempLateListRequest;
import com.tuanzi.loan.vo.response.family.LoanLargeOuterTempLateListResponse;
import org.springframework.data.domain.Page;

/**
 * User: liangZongXi
 * Create time: 16:00 2019/6/4
 * Description:
 */
public class LoanLargeOuterTemplateListLazyDataModel extends BaseLazyDataModel<LoanLargeOuterTempLateListRequest, LoanLargeOuterTempLateListResponse> {
    private static final long serialVersionUID = 9043917982033330166L;

    private LoanLargeOuterTemplateService loanLargeOuterTemplateService = SpringContextHolder.getBean(LoanLargeOuterTemplateService.class);

    public LoanLargeOuterTemplateListLazyDataModel(LoanLargeOuterTempLateListRequest loanLargeOuterTempLateListRequest) {
        super(loanLargeOuterTempLateListRequest);
    }

    @Override
    protected Page<LoanLargeOuterTempLateListResponse> doLoad(PageSearcher<LoanLargeOuterTempLateListRequest> pageSearcher) {
        return loanLargeOuterTemplateService.list(pageSearcher);
    }
}
